<?php



class ZonesToGeoZonesMapBuilder {

	
	const CLASS_NAME = 'lib.model.map.ZonesToGeoZonesMapBuilder';

	
	private $dbMap;

	
	public function isBuilt()
	{
		return ($this->dbMap !== null);
	}

	
	public function getDatabaseMap()
	{
		return $this->dbMap;
	}

	
	public function doBuild()
	{
		$this->dbMap = Propel::getDatabaseMap('propel');

		$tMap = $this->dbMap->addTable('zones_to_geo_zones');
		$tMap->setPhpName('ZonesToGeoZones');

		$tMap->setUseIdGenerator(true);

		$tMap->addPrimaryKey('ASSOCIATION_ID', 'AssociationId', 'int', CreoleTypes::INTEGER, true, null);

		$tMap->addColumn('ZONE_COUNTRY_ID', 'ZoneCountryId', 'int', CreoleTypes::INTEGER, true, null);

		$tMap->addForeignPrimaryKey('ZONE_ID', 'ZoneId', 'int' , CreoleTypes::INTEGER, 'zones', 'ZONE_ID', true, null);

		$tMap->addForeignPrimaryKey('GEO_ZONE_ID', 'GeoZoneId', 'int' , CreoleTypes::INTEGER, 'geo_zones', 'GEO_ZONE_ID', true, null);

		$tMap->addColumn('CREATED_AT', 'CreatedAt', 'int', CreoleTypes::TIMESTAMP, false, null);

		$tMap->addColumn('UPDATED_AT', 'UpdatedAt', 'int', CreoleTypes::TIMESTAMP, false, null);

		$tMap->addColumn('DELETED_AT', 'DeletedAt', 'int', CreoleTypes::TIMESTAMP, false, null);

	} 
} 